package com.shop.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.shop.dao.GoodsDao;
import com.shop.domain.Comment;
import com.shop.domain.Goods;
import com.shop.service.GoodsService;
import com.shop.util.page.PageList;

/**
 * 
 * @author wenjuanhenxing
 * @version V1.0 GoodsServiceImpl.java 2016-2-14 上午10:48:36
 */
@Service("goodsServiceImpl")
public class GoodsServiceImpl implements GoodsService {

	@Resource(name = "goodsDaoImpl")
	private GoodsDao goodsDao;

	@Override
	public boolean addGoods(Goods goods) {
		return goodsDao.addGoods(goods);
	}

	@Override
	public Goods getGoodsById(Long id) {
		return goodsDao.getGoodsById(id);
	}

	@Override
	public List<Goods> getAllGoods() {
		return goodsDao.getAllGoods();
	}

	@Override
	public List<Goods> getGoodsByLargeCategory(Integer largeCategory) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<Goods> getGoodsBySmallCategory(Integer smallCategory) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<Goods> getGoodsByPrice(double low, double high) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public List<Comment> getCommentsByGoodsId(Long id) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public boolean updateName(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateLargeCategory(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateSmallCategory(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updatePrice(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateDegree(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateStock(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateRecentUpdate(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateOnlineStatus(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateCollectCnt(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateTransactionMode(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateTransactionAddress(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public boolean updateDescription(Goods goods) {
		// TODO Auto-generated method stub
		return false;
	}

	@Override
	public List<Goods> getGoodsByPage(PageList pageList) {
		return goodsDao.getGoodsByPage(pageList.getCurrentCount(),
				pageList.getRowsPerPage());
	}

	@Override
	public boolean updateImage(Goods goods) {
		return goodsDao.updateImage(goods);
	}

	@Override
	public List<Goods> getGoodsByCategoryId(Integer categoryId) {
		return goodsDao.getGoodsByCategoryId(categoryId);
	}

	@Override
	public List<Goods> getGoodsByNameLike(String name) {
		return goodsDao.getGoodsByNameLike(name);
	}

}
